package com.health.teahouse.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.health.teahouse.mapper.MeatsMapper;
import com.health.teahouse.domain.Meats;
import com.health.teahouse.service.IMeatsService;

/**
 * 肉品信息Service业务层处理
 * 
 * @author yangzw
 * @date 2024-01-10
 */
@Service
public class MeatsServiceImpl implements IMeatsService 
{
    @Autowired
    private MeatsMapper meatsMapper;

    /**
     * 查询肉品信息
     * 
     * @param meatId 肉品信息主键
     * @return 肉品信息
     */
    @Override
    public Meats selectMeatsByMeatId(Long meatId)
    {
        return meatsMapper.selectMeatsByMeatId(meatId);
    }

    /**
     * 查询肉品信息列表
     * 
     * @param meats 肉品信息
     * @return 肉品信息
     */
    @Override
    public List<Meats> selectMeatsList(Meats meats)
    {
        return meatsMapper.selectMeatsList(meats);
    }

    /**
     * 新增肉品信息
     * 
     * @param meats 肉品信息
     * @return 结果
     */
    @Override
    public int insertMeats(Meats meats)
    {
        return meatsMapper.insertMeats(meats);
    }

    /**
     * 修改肉品信息
     * 
     * @param meats 肉品信息
     * @return 结果
     */
    @Override
    public int updateMeats(Meats meats)
    {
        return meatsMapper.updateMeats(meats);
    }

    /**
     * 批量删除肉品信息
     * 
     * @param meatIds 需要删除的肉品信息主键
     * @return 结果
     */
    @Override
    public int deleteMeatsByMeatIds(Long[] meatIds)
    {
        return meatsMapper.deleteMeatsByMeatIds(meatIds);
    }

    /**
     * 删除肉品信息信息
     * 
     * @param meatId 肉品信息主键
     * @return 结果
     */
    @Override
    public int deleteMeatsByMeatId(Long meatId)
    {
        return meatsMapper.deleteMeatsByMeatId(meatId);
    }
}
